package com.grj.parking.drools.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
import lombok.Data;

/**
 * 车位预约记录表
 * @TableName parking_reservation
 */
@TableName(value ="parking_reservation")
@Data
public class ParkingReservation implements Serializable {
    /**
     * 预约ID
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    /**
     * 预约单号（唯一）
     */
    @TableField(value = "reservation_no")
    private String reservationNo;

    /**
     * 租户ID
     */
    @TableField(value = "tenant_id")
    private Long tenantId;

    /**
     * 用户ID
     */
    @TableField(value = "user_id")
    private Long userId;

    /**
     * 停车场ID
     */
    @TableField(value = "parking_id")
    private Long parkingId;

    /**
     * 车位ID
     */
    @TableField(value = "space_id")
    private Long spaceId;

    /**
     * 车牌号
     */
    @TableField(value = "license_plate")
    private String licensePlate;

    /**
     * 车型：SMALL-小型车，MEDIUM-中型车，LARGE-大型车
     */
    @TableField(value = "car_type")
    private String carType;

    /**
     * 预约开始时间（车位锁定开始时间）
     */
    @TableField(value = "start_time")
    private Date startTime;

    /**
     * 预约结束时间（车位锁定结束时间）
     */
    @TableField(value = "end_time")
    private Date endTime;

    /**
     * 预计到达时间
     */
    @TableField(value = "expected_arrival_time")
    private Date expectedArrivalTime;

    /**
     * 最晚到达时间（超时自动取消）
     */
    @TableField(value = "latest_arrival_time")
    private Date latestArrivalTime;

    /**
     * 预约押金
     */
    @TableField(value = "deposit")
    private BigDecimal deposit;

    /**
     * 预估停车费
     */
    @TableField(value = "parking_fee")
    private BigDecimal parkingFee;

    /**
     * 实际停车费
     */
    @TableField(value = "actual_fee")
    private BigDecimal actualFee;

    /**
     * 状态：CONFIRMED-已确认，USED-已使用，CANCELLED-已取消，EXPIRED-已过期，COMPLETED-已完成
     */
    @TableField(value = "status")
    private String status;

    /**
     * 预约二维码URL
     */
    @TableField(value = "qr_code")
    private String qrCode;

    /**
     * 延长次数（最多2次）
     */
    @TableField(value = "extend_count")
    private Integer extendCount;

    /**
     * 取消原因
     */
    @TableField(value = "cancel_reason")
    private String cancelReason;

    /**
     * 取消时间
     */
    @TableField(value = "cancel_time")
    private Date cancelTime;

    /**
     * 
     */
    @TableField(value = "create_time")
    private Date createTime;

    /**
     * 
     */
    @TableField(value = "update_time")
    private Date updateTime;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;
}